#include"ipAddressPort.h"

#include<sstream>
#include<iostream>
IpAddressPort::IpAddressPort(std::string ip,unsigned short port):ip_(ip),port_(port)
{

}
 std::string IpAddressPort::ToString()const
 {
        std::stringstream ss;
        ss<<ip_<<" : "<<port_;
        return ss.str();
 }
 void IpAddressPort::SetIpAddress(std::string ip)
 {
     ip_ = ip;
 }
 std::string IpAddressPort::GetIpAddress()const
 {
    return ip_;
 }
 void IpAddressPort::SetPort(unsigned short port)
{
  port_ = port;
}
 unsigned short IpAddressPort::GetPort()const
 {
      return port_;
 }
